﻿using System;
using Microsoft.SharePoint;
using Microsoft.SharePoint.WebControls;

namespace DissingConsulting.CreateHostNamedSiteCollection
{
    public partial class CreateSiteCollectionDone : LayoutsPageBase
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Request.QueryString["error"] != null)
            {
                TitleInTitleArea.Text = "Error!";
                Title.Text = "Error!";
                message.Text = Request.QueryString["error"].ToString();
            }
            else if(Request.QueryString["url"] != null)
            {
                message.Text = string.Format("The site collection was created <a href='{0}' target='_blank'>{0}</a>", Request.QueryString["url"].ToString());
            }
        }
    }
}
